package com.irs.irsforum.mapper;

import com.baomidou.mybatisplus.mapper.BaseMapper;
import com.irs.irsforum.entity.Message;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author yihuili
 * @since 2020-02-12
 */
@Mapper
public interface MessageMapper extends BaseMapper<Message> {
    List<Message> getMessageList(@Param("userId") Long userId);

    Integer setRead(@Param("userId") Long userId, @Param("id") Long id);

    Integer delMessage(@Param("userId") Long userId, @Param("id") Long id);

    Integer writeMessage(Message message);
}
